﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using SharpBolt.BasicIntefaces;
using SharpBolt.Time;
using SharpBolt.Graphics;
using SharpBolt.Input;
using SharpBolt.Tweening;

namespace SharpBolt
{
    public class Engine
    {
        public static bool EditTime { get; set; }
        public static string ResourcesPrefix { get; set; }
        public static IMiscs Miscs { get; set; }
        public static IGraphicRender GraphicRender { get; set; }
        public static ISoundRender SoundRender { get; set; }
        public static TimeManager TimeManager { get; set; }
        public static InputObserver InputObserver { get; set; }
        public static Painter DefaultPainter{get;set;}
        public static TweeningManager TweeningManager { get; set; }


        private static Random random;
        public static Random Random
        {
            get {
                if (random == null) random = new Random();
                return Engine.random; }
        }
        public static int RandSign{
            get
            {
                if (Random.NextDouble() > .5)
                    return 1;
                else
                    return -1;
            }
        }
    }
}
